package org.example.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;


/**
 * @Author：无敌暴龙战士
 * @Package：org.example.config
 * @Project：learn_spring_security
 * @name：WebSecurityConfig
 * @Date：2025/2/12 5:13
 * @Filename：WebSecurityConfig
 * @Description:
 */
@Configuration
public class WebSecurityConfig extends WebSecurityConfigurerAdapter {


    @Override
    protected void configure(HttpSecurity http) throws Exception {
        // 允许所有请求
        http.authorizeRequests().anyRequest().permitAll();
        http.formLogin().permitAll();
    }
}
